# -*- coding: utf-8 -*-

###########################################################################
## Python code generated with wxFormBuilder (version 3.10.1-0-g8feb16b3)
## http://www.wxformbuilder.org/
##
## PLEASE DO *NOT* EDIT THIS FILE!
###########################################################################

import wx
import wx.xrc
import wx.propgrid as pg

###########################################################################
## Class LLMidiImportMainPanel
###########################################################################

class LLMidiImportMainPanel ( wx.Panel ):

    def __init__( self, parent, id = wx.ID_ANY, pos = wx.DefaultPosition, size = wx.Size( 714,704 ), style = wx.TAB_TRAVERSAL, name = wx.EmptyString ):
        wx.Panel.__init__ ( self, parent, id = id, pos = pos, size = size, style = style, name = name )

        main_page_sizer = wx.BoxSizer( wx.VERTICAL )

        s_MidiBrowseSizer = wx.StaticBoxSizer( wx.StaticBox( self, wx.ID_ANY, u"选择需要导入的Midi文件" ), wx.VERTICAL )

        self.m_filePicker1 = wx.FilePickerCtrl( s_MidiBrowseSizer.GetStaticBox(), wx.ID_ANY, wx.EmptyString, u"选择需要导入的Midi文件", u"Midi数字乐谱 (*.mid;*.midi)|*.mid;*.midi", wx.DefaultPosition, wx.DefaultSize, wx.FLP_FILE_MUST_EXIST|wx.FLP_OPEN|wx.FLP_USE_TEXTCTRL )
        s_MidiBrowseSizer.Add( self.m_filePicker1, 0, wx.ALL|wx.EXPAND, 5 )


        main_page_sizer.Add( s_MidiBrowseSizer, 0, wx.EXPAND, 5 )

        s_promptSizer = wx.StaticBoxSizer( wx.StaticBox( self, wx.ID_ANY, u"基本参数" ), wx.VERTICAL )

        ss_regularPromoptsEnteringSizer1 = wx.BoxSizer( wx.HORIZONTAL )

        sss_VolumnPersentageEnteringSizer = wx.StaticBoxSizer( wx.StaticBox( s_promptSizer.GetStaticBox(), wx.ID_ANY, u"最小音量" ), wx.HORIZONTAL )

        self.m_volumn_slider = wx.Slider( sss_VolumnPersentageEnteringSizer.GetStaticBox(), wx.ID_ANY, 1000, 0, 1000, wx.DefaultPosition, wx.DefaultSize, wx.SL_HORIZONTAL )
        sss_VolumnPersentageEnteringSizer.Add( self.m_volumn_slider, 0, 0, 5 )

        self.m_volumn_spinCtrlDouble1 = wx.SpinCtrlDouble( sss_VolumnPersentageEnteringSizer.GetStaticBox(), wx.ID_ANY, u"0.1", wx.DefaultPosition, wx.DefaultSize, wx.ALIGN_CENTER_HORIZONTAL|wx.SP_ARROW_KEYS|wx.TE_PROCESS_ENTER, 0, 1, 0.100000, 0.001 )
        self.m_volumn_spinCtrlDouble1.SetDigits( 3 )
        sss_VolumnPersentageEnteringSizer.Add( self.m_volumn_spinCtrlDouble1, 0, 0, 5 )


        ss_regularPromoptsEnteringSizer1.Add( sss_VolumnPersentageEnteringSizer, 0, wx.EXPAND|wx.RIGHT, 5 )

        sss_SpeedEnteringSizer = wx.StaticBoxSizer( wx.StaticBox( s_promptSizer.GetStaticBox(), wx.ID_ANY, u"播放倍速" ), wx.HORIZONTAL )

        self.m_speed_slider = wx.Slider( sss_SpeedEnteringSizer.GetStaticBox(), wx.ID_ANY, 50, 0, 100, wx.DefaultPosition, wx.DefaultSize, wx.SL_HORIZONTAL )
        sss_SpeedEnteringSizer.Add( self.m_speed_slider, 0, 0, 5 )

        self.m_speed_spinCtrlDouble = wx.SpinCtrlDouble( sss_SpeedEnteringSizer.GetStaticBox(), wx.ID_ANY, u"1", wx.DefaultPosition, wx.DefaultSize, wx.ALIGN_CENTER_HORIZONTAL|wx.SP_ARROW_KEYS|wx.TE_PROCESS_ENTER, 0.01, 10, 1, 0.1 )
        self.m_speed_spinCtrlDouble.SetDigits( 2 )
        sss_SpeedEnteringSizer.Add( self.m_speed_spinCtrlDouble, 0, 0, 5 )


        ss_regularPromoptsEnteringSizer1.Add( sss_SpeedEnteringSizer, 0, wx.EXPAND|wx.RIGHT|wx.LEFT, 5 )

        sss_DeviationEnteringSizer1 = wx.StaticBoxSizer( wx.StaticBox( s_promptSizer.GetStaticBox(), wx.ID_ANY, u"音调偏移" ), wx.HORIZONTAL )

        self.m_volumn_slider1 = wx.Slider( sss_DeviationEnteringSizer1.GetStaticBox(), wx.ID_ANY, 0, -16000, 16000, wx.DefaultPosition, wx.DefaultSize, wx.SL_HORIZONTAL )
        sss_DeviationEnteringSizer1.Add( self.m_volumn_slider1, 0, 0, 5 )

        self.m_volumn_spinCtrlDouble11 = wx.SpinCtrlDouble( sss_DeviationEnteringSizer1.GetStaticBox(), wx.ID_ANY, u"0.0", wx.DefaultPosition, wx.DefaultSize, wx.ALIGN_CENTER_HORIZONTAL|wx.SP_ARROW_KEYS|wx.TE_PROCESS_ENTER, -16, 16, 0, 0.001 )
        self.m_volumn_spinCtrlDouble11.SetDigits( 3 )
        sss_DeviationEnteringSizer1.Add( self.m_volumn_spinCtrlDouble11, 0, 0, 5 )


        ss_regularPromoptsEnteringSizer1.Add( sss_DeviationEnteringSizer1, 0, wx.EXPAND|wx.LEFT, 5 )


        s_promptSizer.Add( ss_regularPromoptsEnteringSizer1, 0, wx.EXPAND, 5 )


        main_page_sizer.Add( s_promptSizer, 0, wx.SHAPED|wx.EXPAND, 5 )

        setting_page_sizer = wx.BoxSizer( wx.VERTICAL )

        self.setting_notebook = wx.Notebook( self, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, wx.NB_FIXEDWIDTH|wx.NB_MULTILINE|wx.NB_RIGHT )
        self.setting_notebook.SetFont( wx.Font( wx.NORMAL_FONT.GetPointSize(), wx.FONTFAMILY_DEFAULT, wx.FONTSTYLE_NORMAL, wx.FONTWEIGHT_NORMAL, False, "@OPPOSans R" ) )
        self.setting_notebook.SetBackgroundColour( wx.SystemSettings.GetColour( wx.SYS_COLOUR_WINDOW ) )

        self.setting_page_pitched_inst = wx.Panel( self.setting_notebook, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, wx.TAB_TRAVERSAL )
        self.setting_page_pitched_inst.SetFont( wx.Font( wx.NORMAL_FONT.GetPointSize(), wx.FONTFAMILY_DEFAULT, wx.FONTSTYLE_NORMAL, wx.FONTWEIGHT_NORMAL, False, wx.EmptyString ) )

        setting_page2_box_sizer = wx.BoxSizer( wx.VERTICAL )

        m_pitched_instrument_table_choiceChoices = [ u"“偷吃”的对照表", u"“经典”对照表", u"“断联”的对照表" ]
        self.m_pitched_instrument_table_choice = wx.Choice( self.setting_page_pitched_inst, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, m_pitched_instrument_table_choiceChoices, 0 )
        self.m_pitched_instrument_table_choice.SetSelection( 0 )
        self.m_pitched_instrument_table_choice.SetFont( wx.Font( wx.NORMAL_FONT.GetPointSize(), wx.FONTFAMILY_DEFAULT, wx.FONTSTYLE_NORMAL, wx.FONTWEIGHT_NORMAL, False, "OPPOSans R" ) )

        setting_page2_box_sizer.Add( self.m_pitched_instrument_table_choice, 0, wx.ALL|wx.EXPAND, 5 )

        self.m_pitched_notes_table_propertyGrid1 = pg.PropertyGrid(self.setting_page_pitched_inst, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, wx.propgrid.PG_BOLD_MODIFIED|wx.propgrid.PG_HIDE_MARGIN|wx.propgrid.PG_SPLITTER_AUTO_CENTER)
        self.m_pitched_notes_table_propertyGrid1.SetFont( wx.Font( wx.NORMAL_FONT.GetPointSize(), wx.FONTFAMILY_DEFAULT, wx.FONTSTYLE_NORMAL, wx.FONTWEIGHT_NORMAL, False, "OPPOSans R" ) )

        self.m_propertyGridItem1 = self.m_pitched_notes_table_propertyGrid1.Append( pg.StringProperty( u"乐音乐器1", u"乐音乐器1" ) )
        self.m_propertyGridItem2 = self.m_pitched_notes_table_propertyGrid1.Append( pg.StringProperty( u"乐音乐器2", u"乐音乐器2" ) )
        setting_page2_box_sizer.Add( self.m_pitched_notes_table_propertyGrid1, 1, wx.ALL|wx.EXPAND, 5 )


        self.setting_page_pitched_inst.SetSizer( setting_page2_box_sizer )
        self.setting_page_pitched_inst.Layout()
        setting_page2_box_sizer.Fit( self.setting_page_pitched_inst )
        self.setting_notebook.AddPage( self.setting_page_pitched_inst, u"乐音乐器对照表", True )
        self.setting_page_perc_inst = wx.Panel( self.setting_notebook, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, wx.TAB_TRAVERSAL )
        setting_page3_box_sizer = wx.BoxSizer( wx.VERTICAL )

        m_percussion_instrument_table_choice1Choices = [ u"“偷吃”的对照表", u"“经典”对照表", u"“断联”的对照表" ]
        self.m_percussion_instrument_table_choice1 = wx.Choice( self.setting_page_perc_inst, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, m_percussion_instrument_table_choice1Choices, 0 )
        self.m_percussion_instrument_table_choice1.SetSelection( 0 )
        self.m_percussion_instrument_table_choice1.SetFont( wx.Font( wx.NORMAL_FONT.GetPointSize(), wx.FONTFAMILY_DEFAULT, wx.FONTSTYLE_NORMAL, wx.FONTWEIGHT_NORMAL, False, "OPPOSans R" ) )

        setting_page3_box_sizer.Add( self.m_percussion_instrument_table_choice1, 0, wx.ALL|wx.EXPAND, 5 )

        self.m_percussion_notes_table_propertyGrid11 = pg.PropertyGrid(self.setting_page_perc_inst, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, wx.propgrid.PG_BOLD_MODIFIED|wx.propgrid.PG_HIDE_MARGIN|wx.propgrid.PG_SPLITTER_AUTO_CENTER)
        self.m_percussion_notes_table_propertyGrid11.SetFont( wx.Font( wx.NORMAL_FONT.GetPointSize(), wx.FONTFAMILY_DEFAULT, wx.FONTSTYLE_NORMAL, wx.FONTWEIGHT_NORMAL, False, "OPPOSans R" ) )

        self.m_propertyGridItem11 = self.m_percussion_notes_table_propertyGrid11.Append( pg.StringProperty( u"打击乐器1", u"打击乐器1" ) )
        self.m_propertyGridItem21 = self.m_percussion_notes_table_propertyGrid11.Append( pg.StringProperty( u"打击乐器2", u"打击乐器2" ) )
        setting_page3_box_sizer.Add( self.m_percussion_notes_table_propertyGrid11, 1, wx.ALL|wx.EXPAND, 5 )


        self.setting_page_perc_inst.SetSizer( setting_page3_box_sizer )
        self.setting_page_perc_inst.Layout()
        setting_page3_box_sizer.Fit( self.setting_page_perc_inst )
        self.setting_notebook.AddPage( self.setting_page_perc_inst, u"打击乐器对照表", False )
        self.setting_page_advanced = wx.Panel( self.setting_notebook, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, wx.TAB_TRAVERSAL )
        self.setting_page_advanced.SetFont( wx.Font( wx.NORMAL_FONT.GetPointSize(), wx.FONTFAMILY_DEFAULT, wx.FONTSTYLE_NORMAL, wx.FONTWEIGHT_NORMAL, False, "OPPOSans R" ) )

        setting_page1_box_sizer = wx.BoxSizer( wx.VERTICAL )

        ss_outputFormatChooseSizer = wx.StaticBoxSizer( wx.StaticBox( self.setting_page_advanced, wx.ID_ANY, u"选择音距处理曲线" ), wx.VERTICAL )

        m_outformatChoice_choice1Choices = [ u"自然拟合线", u"线性直线" ]
        self.m_outformatChoice_choice1 = wx.Choice( ss_outputFormatChooseSizer.GetStaticBox(), wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, m_outformatChoice_choice1Choices, 0 )
        self.m_outformatChoice_choice1.SetSelection( 0 )
        ss_outputFormatChooseSizer.Add( self.m_outformatChoice_choice1, 0, wx.ALL|wx.EXPAND, 5 )


        setting_page1_box_sizer.Add( ss_outputFormatChooseSizer, 0, wx.ALL|wx.EXPAND, 5 )

        setting_page1_experiment_style = wx.StaticBoxSizer( wx.StaticBox( self.setting_page_advanced, wx.ID_ANY, u"实验性转换功能" ), wx.HORIZONTAL )

        self.m_enable_experiment_checkBox = wx.CheckBox( setting_page1_experiment_style.GetStaticBox(), wx.ID_ANY, u"启用实验性功能", wx.DefaultPosition, wx.DefaultSize, 0 )
        setting_page1_experiment_style.Add( self.m_enable_experiment_checkBox, 1, wx.ALL|wx.EXPAND, 5 )

        experiment_type_choiceChoices = [ u"常规转换", u"长音插值", u"同刻偏移" ]
        self.experiment_type_choice = wx.Choice( setting_page1_experiment_style.GetStaticBox(), wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, experiment_type_choiceChoices, 0 )
        self.experiment_type_choice.SetSelection( 0 )
        setting_page1_experiment_style.Add( self.experiment_type_choice, 2, wx.ALL|wx.EXPAND, 5 )

        self.m_ignore_midi_error_checkBox = wx.CheckBox( setting_page1_experiment_style.GetStaticBox(), wx.ID_ANY, u"忽略MIDI错误", wx.DefaultPosition, wx.DefaultSize, 0 )
        self.m_ignore_midi_error_checkBox.SetValue(True)
        setting_page1_experiment_style.Add( self.m_ignore_midi_error_checkBox, 1, wx.ALL, 5 )


        setting_page1_box_sizer.Add( setting_page1_experiment_style, 0, wx.ALL|wx.EXPAND, 5 )


        self.setting_page_advanced.SetSizer( setting_page1_box_sizer )
        self.setting_page_advanced.Layout()
        setting_page1_box_sizer.Fit( self.setting_page_advanced )
        self.setting_notebook.AddPage( self.setting_page_advanced, u"高级设置", False )

        setting_page_sizer.Add( self.setting_notebook, 1, wx.EXPAND |wx.ALL, 5 )


        main_page_sizer.Add( setting_page_sizer, 8, wx.EXPAND, 5 )


        self.SetSizer( main_page_sizer )
        self.Layout()

        # Connect Events
        self.m_volumn_slider.Bind( wx.EVT_SCROLL, self.onVolumeScrolling )
        self.m_volumn_spinCtrlDouble1.Bind( wx.EVT_SPINCTRLDOUBLE, self.onVolumeSpinChanged )
        self.m_speed_slider.Bind( wx.EVT_SCROLL, self.onSpeedScrolling )
        self.m_speed_spinCtrlDouble.Bind( wx.EVT_SPINCTRLDOUBLE, self.onSpeedSpinChanged )
        self.m_volumn_slider1.Bind( wx.EVT_SCROLL, self.onVolumeScrolling )
        self.m_volumn_spinCtrlDouble11.Bind( wx.EVT_SPINCTRLDOUBLE, self.onVolumeSpinChanged )
        self.m_pitched_instrument_table_choice.Bind( wx.EVT_CHOICE, self.onPitchedInstListChanging )
        self.m_pitched_notes_table_propertyGrid1.Bind( pg.EVT_PG_CHANGED, self.onPitchedInstTableChanged )
        self.m_pitched_notes_table_propertyGrid1.Bind( pg.EVT_PG_CHANGING, self.onPitchedInstTableChanging )
        self.m_percussion_instrument_table_choice1.Bind( wx.EVT_CHOICE, self.onPercussionInstListChanging )
        self.m_percussion_notes_table_propertyGrid11.Bind( pg.EVT_PG_CHANGED, self.onPercussionInstTableChanged )
        self.m_percussion_notes_table_propertyGrid11.Bind( pg.EVT_PG_CHANGING, self.onPercussionInstTableChanging )
        self.m_outformatChoice_choice1.Bind( wx.EVT_CHOICE, self.onOutputFormatChosen )
        self.m_enable_experiment_checkBox.Bind( wx.EVT_CHECKBOX, self.onExperimentEnableUpdating )
        self.experiment_type_choice.Bind( wx.EVT_CHOICE, self.onConvertMethodUpdating )
        self.m_ignore_midi_error_checkBox.Bind( wx.EVT_CHECKBOX, self.onMidiFaultIgnoranceChecking )

    def __del__( self ):
        pass


    # Virtual event handlers, override them in your derived class
    def onVolumeScrolling( self, event ):
        event.Skip()

    def onVolumeSpinChanged( self, event ):
        event.Skip()

    def onSpeedScrolling( self, event ):
        event.Skip()

    def onSpeedSpinChanged( self, event ):
        event.Skip()



    def onPitchedInstListChanging( self, event ):
        event.Skip()

    def onPitchedInstTableChanged( self, event ):
        event.Skip()

    def onPitchedInstTableChanging( self, event ):
        event.Skip()

    def onPercussionInstListChanging( self, event ):
        event.Skip()

    def onPercussionInstTableChanged( self, event ):
        event.Skip()

    def onPercussionInstTableChanging( self, event ):
        event.Skip()

    def onOutputFormatChosen( self, event ):
        event.Skip()

    def onExperimentEnableUpdating( self, event ):
        event.Skip()

    def onConvertMethodUpdating( self, event ):
        event.Skip()

    def onMidiFaultIgnoranceChecking( self, event ):
        event.Skip()


